package com.cgtong.android.mvp.contract;

import com.cgtong.android.bean.ProblemBean;
import com.cgtong.android.http.callback.BaseCallBack;
import com.zhouyou.http.exception.ApiException;
import com.zhouyou.http.model.ApiResult;

import java.util.List;

/**
 * Created by chunc on 2018/1/3.
 */

public interface RecycleListContract {
    interface Model {

        void httpRecycleList(long maxId, String searchKey, long userId, BaseCallBack<List<ProblemBean>> baseCallBack);

        void commitRecycleProblemIDs(String ids, BaseCallBack<ApiResult> baseCallBack);
        void deleteRecycles(String ids, BaseCallBack<ApiResult> baseCallBack);

    }

    interface View {

        void setRefreshing(boolean isRefresh);

        void setEnableLoadMore(boolean enableLoadMore);

        void onLoadMoreEnd(boolean isLoadMoreEnd);

        void onError(ApiException e);

        void onNullData();

        void onHttpRecycleListSuccess(List<ProblemBean> datas, boolean isRefresh);

        void onCommitRecycleProblemIDsSuccess(ApiResult result);
        void onDeleteRecycleIDsSuccess(ApiResult result);

    }

    interface Presenter {

        void httpRecycleList(long maxId, String searchKey, long userId, boolean isRefresh);

        void commitRecycleProblemIDs(String ids);
        void deleteRecycles(String ids);

        void onDestroy();

    }
}
